Optimal. Leaf size=105 \[ \frac{x \sqrt{a^2+2 a b x+b^2 x^2} (a B+A b)}{a+b x}+\frac{a A \log (x) \sqrt{a^2+2 a b x+b^2 x^2}}{a+b x}+\frac{b B x^2 \sqrt{a^2+2 a b x+b^2 x^2}}{2 (a+b x)} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0400829, antiderivative size = 105, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 29, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.069, Rules used = {770, 76} \[ \frac{x \sqrt{a^2+2 a b x+b^2 x^2} (a B+A b)}{a+b x}+\frac{a A \log (x) \sqrt{a^2+2 a b x+b^2 x^2}}{a+b x}+\frac{b B x^2 \sqrt{a^2+2 a b x+b^2 x^2}}{2 (a+b x)} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 770
Rule 76
Rubi steps
\begin{align*} \int \frac{(A+B x) \sqrt{a^2+2 a b x+b^2 x^2}}{x} \, dx &=\frac{\sqrt{a^2+2 a b x+b^2 x^2} \int \frac{\left (a b+b^2 x\right ) (A+B x)}{x} \, dx}{a b+b^2 x}\\ &=\frac{\sqrt{a^2+2 a b x+b^2 x^2} \int \left (b (A b+a B)+\frac{a A b}{x}+b^2 B x\right ) \, dx}{a b+b^2 x}\\ &=\frac{(A b+a B) x \sqrt{a^2+2 a b x+b^2 x^2}}{a+b x}+\frac{b B x^2 \sqrt{a^2+2 a b x+b^2 x^2}}{2 (a+b x)}+\frac{a A \sqrt{a^2+2 a b x+b^2 x^2} \log (x)}{a+b x}\\ \end{align*}
Mathematica [A] time = 0.0213964, size = 44, normalized size = 0.42 \[ \frac{\sqrt{(a+b x)^2} (x (2 a B+2 A b+b B x)+2 a A \log (x))}{2 (a+b x)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] time = 0.036, size = 53, normalized size = 0.5 \begin{align*}{\frac{{\it csgn} \left ( bx+a \right ) \left ({b}^{2}B{x}^{2}+2\,Aab\ln \left ( bx \right ) +2\,A{b}^{2}x+2\,abBx+2\,Aab+B{a}^{2} \right ) }{2\,b}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.35756, size = 57, normalized size = 0.54 \begin{align*} \frac{1}{2} \, B b x^{2} + A a \log \left (x\right ) +{\left (B a + A b\right )} x \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 0.457625, size = 22, normalized size = 0.21 \begin{align*} A a \log{\left (x \right )} + \frac{B b x^{2}}{2} + x \left (A b + B a\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.21522, size = 62, normalized size = 0.59 \begin{align*} \frac{1}{2} \, B b x^{2} \mathrm{sgn}\left (b x + a\right ) + B a x \mathrm{sgn}\left (b x + a\right ) + A b x \mathrm{sgn}\left (b x + a\right ) + A a \log \left ({\left | x \right |}\right ) \mathrm{sgn}\left (b x + a\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]